import java.util.Scanner;
//平方数
public class Test {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        long x = sc.nextLong();
        long a = (long)Math.sqrt(x);
        long x1 = a * a, x2 = (a + 1) * (a + 1);
        if(x - x1 < x2 - x) {
            System.out.println(x1);
        }else {
            System.out.println(x2);
        }
    }
    public static void main1(String[] args) {
        Scanner sc = new Scanner(System.in);
        long x = sc.nextLong();
        System.out.println(isSquare(x));
        if(isSquare(x)) {
            System.out.println(x);
        }else {
            long b1 = (long)Math.pow(Math.round(Math.sqrt(x)),2);
            System.out.println(b1);

        }
    }
    public static boolean isSquare(long x) {
        double a = 0;
        if (x >= 0) {
            a = Math.sqrt(x);
        }
        long b = (long)a;
        return a - b == 0;
    }
}
